import Layout from '@/layout'

const suplierRouter = {
  path: '/suplier',
  name: 'suplier-group',
  component: Layout,
  meta: { title: '供应商报表', icon: 'tree', roles: ['m6100'] },
  children: [
    {
      path: 'day',
      component: (resolve) => require(['@/views/suplier-group/day'], resolve),
      name: 'SuplierDayManage',
      remoteParam: { serviceName: 'bi', path: '/api/statistics/supplier/day/' },
      remoteUrl: '',
      meta: { title: '供应商日报', roles: ['m6110'] }
    },
    {
      path: 'month',
      component: (resolve) => require(['@/views/suplier-group/month'], resolve),
      name: 'SuplierMonthManage',
      remoteParam: { serviceName: 'bi', path: '/api/statistics/supplier/month/' },
      remoteUrl: '',
      meta: { title: '供应商月报', roles: ['m6120'] }
    },
    {
      path: 'year',
      component: (resolve) => require(['@/views/suplier-group/year'], resolve),
      name: 'SuplierYearManage',
      remoteParam: { serviceName: 'bi', path: '/api/statistics/supplier/year/' },
      remoteUrl: '',
      meta: { title: '供应商年报', roles: ['m6130'] }
    },
    {
      path: 'top',
      component: (resolve) => require(['@/views/suplier-group/top'], resolve),
      name: 'SuplierTopManage',
      remoteParam: { serviceName: 'bi', path: '/api/statistics/supplier/top/' },
      remoteUrl: '',
      meta: { title: '供应商排行', roles: ['m6140'] }
    }
  ]
}

export default suplierRouter
